﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel;
using System.Text;
using System.Threading.Tasks;
using WcfService.WCFModels;

namespace WcfService
{
    [ServiceContract]
    public interface IStandardService
    {
        // Destination methods
        [OperationContract]
        List<WCFDestination> FindAllDestinations();

        [OperationContract]
        WCFDestination FindDestinationName(string name);

        [OperationContract]
        List<WCFDestination> FindDestinationCountry(string country);

        // Dijkstra method
        [OperationContract]
        WCFCompleteRoute CalculateShortestPath(string from, string to, int check, DateTime date, int seats, bool firstClass);

        // Route methods
        [OperationContract]
        WCFRoute FindRoute(string from, string to);

        [OperationContract]
        WCFPlane FindPlane(DateTime departure, int routeId);

        [OperationContract]
        void ReserveSeats(int check, List<WCFPlane> planeList, int seats);

        [OperationContract]
        void UnreserveSeats(int check, List<WCFPlane> planeList, int seats);

        //User methods
        [OperationContract]
        bool createUserAndOrder(string name, string phoneNo, string mail, double totalPrice, string route);
    }

}
